home *** CD-ROM | disk | FTP | other *** search
- <?xml version="1.0" encoding="utf-8" ?>
- <!DOCTYPE stack PUBLIC "-//Apple, Inc.//DTD stack V 2.0//EN" "" >
- <stack>
- <name>in</name>
- <id>-1</id>
- <cardCount>15</cardCount>
- <cardID>6151</cardID>
- <listID>7244</listID>
- <cantModify><false /></cantModify>
- <cantDelete><false /></cantDelete>
- <cantAbort><false /></cantAbort>
- <cardSize>
- <width>512</width>
- <height>342</height>
- </cardSize>
- <script>-- init stack
- on openStack
- initAll
- end openStack
-
- on resume
- initAll
- pass resume
- end resume
-
- on startUp
- initAll
- pass startUp
- end startUp
-
- on initAll
- push recent card
-
- -- flag whether New Card commands are from user or from XCMD
- global fromXCMD, volumeXCMD,hardDisk,applPath
-
- -- init Find string and buttons
- global sourceString
- put empty into sourceString
- global selectedText, whichButton,whichFindButton
-
- -- the ShowPath XFCN will return an Application's pathname
- --in this global if the "Record" button is clicked
- put empty into applPath
-
- put false into fromXCMD -- New Card command is from user
- put false into hardDisk -- Floppies being cataloged
-
-
- -- field remembers Find dialog box settings between stack uses
- get line 2 of card field "Hold Globals" of card¬
- "AutoCat Index"
- if it is not empty then
- put line 1 of card field "Hold Globals" of card¬
- "AutoCat Index" into selectedText
- put line 2 of card field "Hold Globals" of card¬
- "AutoCat Index" into whichButton
- put line 3 of card field "Hold Globals" of card¬
- "AutoCat Index" into whichFindButton
- else
- -- if it doesn't remember, set defaults
- put empty into selectedText
- put 1 into whichButton
- put 1 into whichFindButton
- end if
- end initAll
-
-
-
- on closeStack
- -- record find dialog box's most recent settings
- global selectedText, whichButton,whichFindButton
- put selectedText into line 1 of card field "Hold Globals" of card¬
- "AutoCat Index"
- put whichButton into line 2 of card field "Hold Globals" of card¬
- "AutoCat Index"
- put whichFindButton into line 3 of card field "Hold Globals" of card¬
- "AutoCat Index"
-
- -- Auto Compact stack if necessary
- if the freeSize of this stack >= 15000 then
- answer "The AutoCat Stack has " & round(the freeSize of this¬
- stack/1024) & "k free, Compact?" with "NO" or "OK"
- if it is "OK" then doMenu "compact stack"
- end if
- end closeStack
-
- --find field line clicked on in a scrlloing field
- Function lineClicked
- return (trunc(((scroll of the target) ¬
- + (item two of the clickloc) ¬
- - (item two of the rect of the target)) ¬
- div the textheight of the target) + one)
- end lineClicked
-
-
- on returnKey
- global sourceString -- last find string
- if sourceString is not empty then -- continue search
- set cursor to 4
- searchAC 0
- else
- pass returnKey
- end if
- end returnKey
-
- on searchAC flag
- -- which field to search, what mode to use, e.g., chars, word...
- -- these globals are maintained by the SearchAutoCat XFCN
- global whichButton,whichFindButton
- -- the source
- global sourceString
-
- -- a simple XFCN which puts up a dialog box looking for the search
- -- string and the options
-
- if flag >0 then
- put SearchAutoCat () into sourceString
- end if
-
- if sourceString is empty then exit searchAC
-
- -- the XFCN returns 1,2, or 3 for which find mode button was set
-
- if whichButton contains 1 then -- search all fields
- if whichFindButton contains 1 then -- look at beginnings of words
- find sourceString
- end if -- wfb 1
- if whichFindButton contains 2 then -- look at words only
- find word sourceString
- end if -- wfb 2
- if whichFindButton contains 3 then -- look at chars
- find chars sourceString
- end if -- wfb 3
- end if -- whichButton
-
- -- XFCN returns 1-8 depending on which field button was set
-
- if whichButton contains 2 then
- SearchFields 9, 3424
- end if
- if whichButton contains 3 then
- SearchFields 1, 3424
- end if
- if whichButton contains 4 then
- SearchFields 1, 2241
- end if
- if whichButton contains 5 then
- SearchFields 2, 2241
- end if
- if whichButton contains 6 then
- SearchFields 61, 2241
- end if
- if whichButton contains 7 then
- SearchFields 62, 2241
- end if
- if whichButton contains 8 then
- SearchFields 50, 2241
- end if
- end searchAC
-
-
- on SearchFields fieldID,bkgndID
- global whichButton,whichFindButton,sourceString
-
- -- go to the proper bkgnd to begin search
- if the ID of this bkgnd is not bkgndID then
- go to bkgnd ID bkgndID
- end if
- if whichFindButton contains 1 then -- look at beginnings of words
- find sourceString in bkgnd field ID fieldID
- end if -- wfb 1
- if whichFindButton contains 2 then -- look at words only
- find word sourceString in bkgnd field ID fieldID
- end if -- wfb 2
- if whichFindButton contains 3 then -- look at chars
- find chars sourceString in bkgnd field ID fieldID
- end if -- wfb 3
- send mouseWithin to bkgnd field ID fieldID
- end SearchFields
-
- on doMenu which
- -- trap command-F to bring up Find dialog box
- if which is "Find..." then
- searchAC 1
- else
- pass doMenu
- end if
- end doMenu
-
- </script>
- <background id="2241" file="background_2241.xml" name="" />
- <background id="2726" file="background_2726.xml" name="Index Card Bkgnd" />
- <background id="3424" file="background_3424.xml" name="" />
- <background id="4606" file="background_4606.xml" name="AutoCat Help Bkgnd" />
- <background id="6410" file="background_6410.xml" name="Application Bkgnd" />
- <card id="6151" file="card_6151.xml" marked="false" name="AutoCat Index" owner="2726" />
- <card id="7767" file="card_7767.xml" marked="false" name="AutoCat Help" owner="4606" />
- <card id="7615" file="card_7615.xml" marked="false" name="AutoCat Help" owner="4606" />
- <card id="3773" file="card_3773.xml" marked="false" name="Search Card" owner="4606" />
- <card id="5441" file="card_5441.xml" marked="false" name="PathWay/Launch" owner="4606" />
- <card id="8578" file="card_8578.xml" marked="false" name="Hard Disk/Record" owner="4606" />
- <card id="6055" file="card_6055.xml" marked="false" name="Printing" owner="4606" />
- <card id="8746" file="card_8746.xml" marked="false" name="XCMDs & XFCNs" owner="4606" />
- <card id="9913" file="card_9913.xml" marked="false" name="Hints & Tips" owner="4606" />
- <card id="9640" file="card_9640.xml" marked="false" name="ShareWare Fee" owner="4606" />
- <card id="6934" file="card_6934.xml" marked="false" name="Applications" owner="6410" />
- <card id="5366" file="card_5366.xml" marked="false" name="Disk Box Index" owner="3424" />
- <card id="4971" file="card_4971.xml" marked="false" name="Box #1.Index" owner="3424" />
- <card id="3043" file="card_3043.xml" marked="false" name=" Disk Cat Template" owner="2241" />
- <card id="5654" file="card_5654.xml" marked="false" name="Box #1 1" owner="2241" />
- </stack>
-